package com.hxd.otc.module.my.adapter;

import android.text.TextUtils;

import com.chad.library.adapter.base.BaseQuickAdapter;
import com.chad.library.adapter.base.BaseViewHolder;
import com.hxd.otc.R;
import com.hxd.otc.module.my.bean.RelataionShipBean;
import com.hxd.otc.utils.UIUtils;

/**
 * 包  名 :  com.hxd.otc.module.order.adapter
 * 类  名 :  OllOrderAdapter
 * 作  者 :  zjl
 * 时  间 :  2018/6/5 18:03
 * 描  述 :  ${全部订单页面}
 */
public class RelationShipAdapter extends BaseQuickAdapter<RelataionShipBean.RelataionShipData, BaseViewHolder> {

    public RelationShipAdapter() {
        super(R.layout.adapter_relation_ship, null);
    }

    @Override
    protected void convert(BaseViewHolder helper, RelataionShipBean.RelataionShipData item) {

        helper.setText(R.id.tv_name, item.recommendName);
        if (!TextUtils.isEmpty(item.upLevelRecommendName))
            helper.setText(R.id.tv_name2, UIUtils.getContext().getString(R.string.one_placeholder, item.upLevelRecommendName));
        helper.setText(R.id.tv_time, item.createTime);

    }
}
